- Eff <A> (Eff<MinRT, A> effect)
- Run (MinRT env)
- Run (EnvIO envIO)
- Run ()
- Timeout (TimeSpan timeoutDelay)
- Pure (A value)
- Fail (Error error)
- Lift (Func<MinRT, Either<Error, A>> f)
- Lift (Func<MinRT, Fin<A>> f)
- Lift (Func<MinRT, A> f)
- LiftIO (Func<MinRT, Task<A>> f)
- LiftIO (Func<MinRT, Task<Fin<A>>> f)
- LiftIO (Func<MinRT, IO<A>> f)
- LiftIO (IO<A> ma)
- Lift (Func<Either<Error, A>> f)
- Lift (Func<Fin<A>> f)
- Lift (Func<A> f)
- LiftIO (Func<Task<A>> f)
- LiftIO (Func<Task<Fin<A>>> f)
- Fork (Option<TimeSpan> timeout = default)
- Map <B> (Func<A, B> f)
- Select <B> (Func<A, B> f)
- MapFail (Func<Error, Error> f)
- MapIO <B> (Func<IO<A>, IO<B>> f)
- BiMap <B> (Func<A, B> Succ, Func<Error, Error> Fail)
- Match <B> (Func<A, B> Succ, Func<Error, B> Fail)
- IfFail (Func<Error, A> Fail)
- IfFailEff (Func<Error, Eff<A>> Fail)
- Filter (Func<A, bool> predicate)
- Where (Func<A, bool> predicate)
- Bind <B> (Func<A, Eff<B>> f)
- Bind <B> (Func<A, IO<B>> f)
- Bind <B> (Func<A, Gets<MinRT, B>> f)
- Bind (Func<A, Put<MinRT>> f)
- Bind (Func<A, Modify<MinRT>> f)
- Bind <RT, B> (Func<A, Eff<RT, B>> f)
- Bind <RT, B> (Func<A, K<Eff<RT>, B>> f)
- Bind <B> (Func<A, K<Eff, B>> f)
- Bind <B> (Func<A, Pure<B>> f)
- Bind (Func<A, Fail<Error>> f)
- SelectMany <B, C> (Func<A, Eff<B>> bind, Func<A, B, C> project)
- SelectMany <RT, B, C> (Func<A, Eff<RT, B>> bind, Func<A, B, C> project)
- SelectMany <RT, B, C> (Func<A, K<Eff<RT>, B>> bind, Func<A, B, C> project)
- SelectMany <B, C> (Func<A, K<Eff, B>> bind, Func<A, B, C> project)
- SelectMany <B, C> (Func<A, Pure<B>> bind, Func<A, B, C> project)
- SelectMany <B, C> (Func<A, IO<B>> bind, Func<A, B, C> project)
- SelectMany <B, C> (Func<A, Gets<MinRT, B>> bind, Func<A, B, C> project)
- SelectMany <C> (Func<A, Modify<MinRT>> bind, Func<A, Unit, C> project)
- SelectMany <C> (Func<A, Put<MinRT>> bind, Func<A, Unit, C> project)
- SelectMany <B, C> (Func<A, Fail<Error>> bind, Func<A, B, C> project)
- SelectMany <C> (Func<A, Guard<Error, Unit>> bind, Func<A, Unit, C> project)
- SelectMany <C> (Func<A, Guard<Fail<Error>, Unit>> bind, Func<A, Unit, C> project)
- Fold <S> ( Schedule schedule, S initialState, Func<S, A, S> folder)
- Fold <S> ( S initialState, Func<S, A, S> folder)
- FoldUntil <S> ( Schedule schedule, S initialState, Func<S, A, S> folder, Func<(S State, A Value), bool> predicate)
- FoldUntil <S> ( Schedule schedule, S initialState, Func<S, A, S> folder, Func<S, bool> stateIs)
- FoldUntil <S> ( Schedule schedule, S initialState, Func<S, A, S> folder, Func<A, bool> valueIs)
- FoldUntil <S> ( S initialState, Func<S, A, S> folder, Func<(S State, A Value), bool> predicate)
- FoldUntil <S> ( S initialState, Func<S, A, S> folder, Func<S, bool> stateIs)
- FoldUntil <S> ( S initialState, Func<S, A, S> folder, Func<A, bool> valueIs)
- FoldWhile <S> ( Schedule schedule, S initialState, Func<S, A, S> folder, Func<(S State, A Value), bool> predicate)
- FoldWhile <S> ( Schedule schedule, S initialState, Func<S, A, S> folder, Func<S, bool> stateIs)
- FoldWhile <S> ( Schedule schedule, S initialState, Func<S, A, S> folder, Func<A, bool> valueIs)
- FoldWhile <S> ( S initialState, Func<S, A, S> folder, Func<(S State, A Value), bool> predicate)
- FoldWhile <S> ( S initialState, Func<S, A, S> folder, Func<S, bool> stateIs)
- FoldWhile <S> ( S initialState, Func<S, A, S> folder, Func<A, bool> valueIs)
- Post ()
- WithRuntime <RT> ()
- | (Eff<A> ma, Eff<A> mb)
- | (Eff<A> ma, Pure<A> mb)
- | (Eff<A> ma, Fail<Error> error)
- | (Eff<A> ma, Error error)
- | (Eff<A> ma, A value)
- | (Eff<A> ma, CatchError<Error> mb)
- | (Eff<A> ma, CatchError mb)
- | (Eff<A> ma, CatchError<Exception> mb)
- | (Eff<A> ma, CatchValue<Error, A> mb)
- | (Eff<A> ma, CatchValue<Exception, A> mb)
- | (Eff<A> ma, CatchValue<A> mb)
- | (Eff<A> ma, CatchM<Eff, A> mb)
- ToString ()
- Success (A value)
- Effect (Func<A> f)
- EffectMaybe (Func<Fin<A>> f)
Sub modules
Extensions |
Prelude |
record Eff <A> (Eff<MinRT, A> effect) Source #
Transducer based effect/Eff
monad
type | RT | Runtime struct |
type | A | Bound value type |
method Eff<A> Timeout (TimeSpan timeoutDelay) Source #
Cancel the operation if it takes too long
param | timeoutDelay | Timeout period |
returns | An IO operation that will timeout if it takes too long |
method Eff<ForkIO<A>> Fork (Option<TimeSpan> timeout = default) Source #
Queue this IO operation to run on the thread-pool.
param | timeout | Maximum time that the forked IO operation can run for. |
returns | Returns a |
method Eff<B> Map <B> (Func<A, B> f) Source #
Maps the Eff
monad if it's in a success state
param | f | Function to map the success value with |
returns | Mapped |
method Eff<B> Select <B> (Func<A, B> f) Source #
Maps the Eff
monad if it's in a success state
param | f | Function to map the success value with |
returns | Mapped |
method Eff<A> MapFail (Func<Error, Error> f) Source #
Maps the Eff
monad if it's in a success state
param | f | Function to map the success value with |
returns | Mapped |
method Eff<B> MapIO <B> (Func<IO<A>, IO<B>> f) Source #
Maps the inner IO monad
param | f | Function to map with |
returns | Mapped |
method Eff<B> BiMap <B> (Func<A, B> Succ, Func<Error, Error> Fail) Source #
Mapping of either the Success state or the Failure state depending on what
state this Eff
monad is in.
param | Succ | Mapping to use if the |
param | Fail | Mapping to use if the |
returns | Mapped |
method Eff<B> Match <B> (Func<A, B> Succ, Func<Error, B> Fail) Source #
Pattern match the success or failure values and collapse them down to a success value
param | Succ | Success value mapping |
param | Fail | Failure value mapping |
returns | IO in a success state |
method Eff<A> IfFail (Func<Error, A> Fail) Source #
Map the failure to a success value
param | f | Function to map the fail value |
returns | IO in a success state |
method Eff<A> IfFailEff (Func<Error, Eff<A>> Fail) Source #
Map the failure to a new IO effect
param | f | Function to map the fail value |
returns | IO that encapsulates that IfFail |
method Eff<A> Filter (Func<A, bool> predicate) Source #
Only allow values through the effect if the predicate returns true
for the bound value
param | predicate | Predicate to apply to the bound value> |
returns | Filtered IO |
method Eff<A> Where (Func<A, bool> predicate) Source #
Only allow values through the effect if the predicate returns true
for the bound value
param | predicate | Predicate to apply to the bound value> |
returns | Filtered IO |
method Eff<B> Bind <B> (Func<A, Eff<B>> f) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | f | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<B> Bind <B> (Func<A, IO<B>> f) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | f | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<B> Bind <B> (Func<A, Gets<MinRT, B>> f) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | f | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<Unit> Bind (Func<A, Put<MinRT>> f) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | f | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<Unit> Bind (Func<A, Modify<MinRT>> f) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | f | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<RT, B> Bind <RT, B> (Func<A, Eff<RT, B>> f) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | f | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<RT, B> Bind <RT, B> (Func<A, K<Eff<RT>, B>> f) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | f | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<B> Bind <B> (Func<A, K<Eff, B>> f) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | f | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<B> Bind <B> (Func<A, Pure<B>> f) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | f | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<A> Bind (Func<A, Fail<Error>> f) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | f | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<C> SelectMany <B, C> (Func<A, Eff<B>> bind, Func<A, B, C> project) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | bind | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<RT, C> SelectMany <RT, B, C> (Func<A, Eff<RT, B>> bind, Func<A, B, C> project) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | bind | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<RT, C> SelectMany <RT, B, C> (Func<A, K<Eff<RT>, B>> bind, Func<A, B, C> project) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | bind | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<C> SelectMany <B, C> (Func<A, K<Eff, B>> bind, Func<A, B, C> project) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | bind | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<C> SelectMany <B, C> (Func<A, Pure<B>> bind, Func<A, B, C> project) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | bind | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<C> SelectMany <B, C> (Func<A, IO<B>> bind, Func<A, B, C> project) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | bind | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<C> SelectMany <B, C> (Func<A, Gets<MinRT, B>> bind, Func<A, B, C> project) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | bind | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<C> SelectMany <C> (Func<A, Modify<MinRT>> bind, Func<A, Unit, C> project) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | bind | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<C> SelectMany <C> (Func<A, Put<MinRT>> bind, Func<A, Unit, C> project) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | bind | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<C> SelectMany <B, C> (Func<A, Fail<Error>> bind, Func<A, B, C> project) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | bind | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<C> SelectMany <C> (Func<A, Guard<Error, Unit>> bind, Func<A, Unit, C> project) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | bind | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<C> SelectMany <C> (Func<A, Guard<Fail<Error>, Unit>> bind, Func<A, Unit, C> project) Source #
Monadic bind operation. This runs the current Eff
monad and feeds its result to the
function provided; which in turn returns a new Eff
monad. This can be thought of as
chaining IO operations sequentially.
param | bind | Bind operation |
returns | Composition of this monad and the result of the function provided |
method Eff<S> Fold <S> ( Schedule schedule, S initialState, Func<S, A, S> folder) Source #
Fold the effect forever or until the schedule expires
method Eff<S> FoldUntil <S> ( Schedule schedule, S initialState, Func<S, A, S> folder, Func<(S State, A Value), bool> predicate) Source #
Fold the effect until the predicate returns true
method Eff<S> FoldUntil <S> ( Schedule schedule, S initialState, Func<S, A, S> folder, Func<S, bool> stateIs) Source #
Fold the effect until the predicate returns true
method Eff<S> FoldUntil <S> ( Schedule schedule, S initialState, Func<S, A, S> folder, Func<A, bool> valueIs) Source #
Fold the effect until the predicate returns true
method Eff<S> FoldUntil <S> ( S initialState, Func<S, A, S> folder, Func<(S State, A Value), bool> predicate) Source #
Fold the effect until the predicate returns true
method Eff<S> FoldUntil <S> ( S initialState, Func<S, A, S> folder, Func<S, bool> stateIs) Source #
Fold the effect until the predicate returns true
method Eff<S> FoldUntil <S> ( S initialState, Func<S, A, S> folder, Func<A, bool> valueIs) Source #
Fold the effect until the predicate returns true
method Eff<S> FoldWhile <S> ( Schedule schedule, S initialState, Func<S, A, S> folder, Func<(S State, A Value), bool> predicate) Source #
Fold the effect while the predicate returns true
method Eff<S> FoldWhile <S> ( Schedule schedule, S initialState, Func<S, A, S> folder, Func<S, bool> stateIs) Source #
Fold the effect while the predicate returns true
method Eff<S> FoldWhile <S> ( Schedule schedule, S initialState, Func<S, A, S> folder, Func<A, bool> valueIs) Source #
Fold the effect while the predicate returns true
method Eff<S> FoldWhile <S> ( S initialState, Func<S, A, S> folder, Func<(S State, A Value), bool> predicate) Source #
Fold the effect while the predicate returns true
method Eff<S> FoldWhile <S> ( S initialState, Func<S, A, S> folder, Func<S, bool> stateIs) Source #
Fold the effect while the predicate returns true
method Eff<S> FoldWhile <S> ( S initialState, Func<S, A, S> folder, Func<A, bool> valueIs) Source #
Fold the effect until the predicate returns true
method Eff<A> Post () Source #
Make the effect run on the SynchronizationContext
that was captured at the start
of an Run
call.
The effect receives its input value from the currently running sync-context and
then proceeds to run its operation in the captured SynchronizationContext
:
typically a UI context, but could be any captured context. The result of the
effect is the received back on the currently running sync-context.
method Eff<RT, A> WithRuntime <RT> () Source #
Convert to an Eff
monad with a runtime
method Eff<A> EffectMaybe (Func<Fin<A>> f) Source #
Lift a synchronous effect into the Eff
monad
operator | (Eff<A> ma, Eff<A> mb) Source #
Run the first IO operation; if it fails, run the second. Otherwise return the result of the first without running the second.
param | ma | First IO operation |
param | mb | Alternative IO operation |
returns | Result of either the first or second operation |
operator | (Eff<A> ma, Pure<A> mb) Source #
Run the first IO operation; if it fails, run the second. Otherwise return the result of the first without running the second.
param | ma | First IO operation |
param | mb | Alternative value if the IO operation fails |
returns | Result of either the first or second operation |
operator | (Eff<A> ma, Fail<Error> error) Source #
Run the first IO operation; if it fails, run the second. Otherwise return the result of the first without running the second.
param | ma | First IO operation |
param | error | Alternative value if the IO operation fails |
returns | Result of either the first or second operation |
operator | (Eff<A> ma, Error error) Source #
Run the first IO operation; if it fails, run the second. Otherwise return the result of the first without running the second.
param | ma | First IO operation |
param | error | Error if the IO operation fails |
returns | Result of either the first or second operation |
operator | (Eff<A> ma, A value) Source #
Run the first IO operation; if it fails, run the second. Otherwise return the result of the first without running the second.
param | ma | First IO operation |
param | value | Alternative value if the IO operation fails |
returns | Result of either the first or second operation |
operator | (Eff<A> ma, CatchError<Error> mb) Source #
Run the first IO operation; if it fails, run the second. Otherwise return the result of the first without running the second.
param | ma | First IO operation |
param | mb | Alternative IO operation |
returns | Result of either the first or second operation |
operator | (Eff<A> ma, CatchError mb) Source #
Run the first IO operation; if it fails, run the second. Otherwise return the result of the first without running the second.
param | ma | First IO operation |
param | mb | Alternative IO operation |
returns | Result of either the first or second operation |
operator | (Eff<A> ma, CatchError<Exception> mb) Source #
Run the first IO operation; if it fails, run the second. Otherwise return the result of the first without running the second.
param | ma | First IO operation |
param | mb | Alternative IO operation |
returns | Result of either the first or second operation |
operator | (Eff<A> ma, CatchValue<Error, A> mb) Source #
Run the first IO operation; if it fails, run the second. Otherwise return the result of the first without running the second.
param | ma | First IO operation |
param | mb | Alternative IO operation |
returns | Result of either the first or second operation |
operator | (Eff<A> ma, CatchValue<Exception, A> mb) Source #
Run the first IO operation; if it fails, run the second. Otherwise return the result of the first without running the second.
param | ma | First IO operation |
param | mb | Alternative IO operation |
returns | Result of either the first or second operation |